Component({
  properties: {},
  data: {
    count: 0,
  },
  methods: {
    // 点击增加
    handleAdd() {
      this.data.count += 1;
      //在子组件中渲染
      this.setData({
        count: this.data.count,
      });
      //子向父传值
      this.triggerEvent("add",this.data.count)
    },
  },
});
